<div class="poll">
        <p class="judulpoll5"> Poll Topic:</p>
        <p class=" judulpoll droid" ><?php if (isset($list_pertanyaan[0]['nama_tema'])) echo $list_pertanyaan[0]['nama_tema'];?><br />
        <span class="judulpollx">| <?php if (isset($list_pertanyaan)) echo count($list_pertanyaan);?> Pertanyaan</span></p>
        <p class="judulpoll2">
        <a href="<?php echo base_url()."polling/polling_con/hasil_topic_all/".$id_tema;?>">All Courses</a> | 
        <a href="<?php echo base_url()."polling/polling_con/specific_course/".$id_tema;?>">Spesific Course</a> | 
        <a href="<?php echo base_url()."polling/polling_con/polling_topic/".$id_tema; ?>">Spesific Class</a> 
        </p>
</div>
<div class="clear"></div>
<div class="bagbawah">
        <div class="par">
                <div class="par4">All Course —<?php echo $jumlah_course;?> Classes </div>
                <div class="droid par2"><?php echo $responden;?></div>
                <div class=" par3">Respondent</div>
        </div>
        <div id="sebelum">
            <div class='hasilnih'>
            <p class="judulpoll3x">Pertanyaan:</p>                
            <?php
            if(!empty($list_pertanyaan)){
                echo '<ul class="tabs">';
                for($i=0;$i<count($list_pertanyaan);$i++){
                    echo '<li><a href="#tab'.($i+1).'">'.($i+1).'</a></li>';                    
                }
                echo '</ul>';
                echo '<div class="tab_container">';
                for($i=0;$i<count($list_pertanyaan);$i++){
                    echo '<div id="tab'.($i+1).'" class="tab_content">';
                    if (($list_pertanyaan[$i]['tipe_pertanyaan']=="multi") || ($list_pertanyaan[$i]['tipe_pertanyaan']=="single")){
                        echo "<p class='judulpoll3'>".$list_pertanyaan[$i]['isi_pertanyaan']."</p>
                            <div class='tempatgrafik kiri' ><span id='grafik' class='sparklines'>";
                            if (isset($list_pertanyaan[$i]['list_jawaban'])){
                                for ($j=0;$j<count($list_pertanyaan[$i]['list_jawaban']);$j++){
                                    if (isset($list_pertanyaan[$i]['list_jawaban'][$j]['persentase'])){
                                        echo $list_pertanyaan[$i]['list_jawaban'][$j]['persentase'].",";
                                    }
                                }
                            }
                            echo "
                            </span></div> <!-- tempatgrafik -->
                            <div class='malam kiri'>";
                            if (isset($list_pertanyaan[$i]['list_jawaban'])){
                                for ($j=0;$j<count($list_pertanyaan[$i]['list_jawaban']);$j++){
                                    if (isset($list_pertanyaan[$i]['list_jawaban'][$j]['persentase'])){
                                        echo "
                                          <p><span class='alebar a".($j+1)."'></span>".$list_pertanyaan[$i]['list_jawaban'][$j]['isi_pilihan']." ".$list_pertanyaan[$i]['list_jawaban'][$j]['persentase']."% <span class='spand'>—".$list_pertanyaan[$i]['list_jawaban'][$j]['votes']." Votes</span></p>
                                        ";
                                    }
                                }
                            }
                            echo"
                            </div> <!-- malam kiri -->
                        ";
                    }else{
                        if (isset($list_pertanyaan[$i]['list_jawaban'])){
                            echo "
                            <p class='judulpoll3'>".$list_pertanyaan[$i]['isi_pertanyaan']."</p>";
                            for ($j=0;$j<=count($list_pertanyaan[$i]['list_jawaban']);$j++){
                                echo "<p>".$list_pertanyaan[$i]['list_jawaban'][$content_counter]['JAWABAN']." <span class='spand'>—".$list_pertanyaan[$i]['list_jawaban'][$content_counter]['NAMA_USER']."</span></p>";
                            }
                        }                        
                    }
                    echo '</div><!-- tab-->';                
                }                
                echo '</div><!-- tab container-->';
            }
            ?>
            </div><!-- hasilnih -->
            <div class='clear'></div>
        </div><!-- end div id sebelum -->
</div><!-- end div id bagbawah -->